/********************************************************
* @file: TestCurva.cpp (v3.81)
* @date: 15/06/2012
* @author: Ricardo C. Marques
**********************************************************/
#ifndef _TESTEXCCRV_H
#define _TESTEXCCRV_H

/*********************** Compilation Settings ****************************/
/* (For Testing and Debugging)  */

/**************** Overview
  Name            Description
CILAMCE                     If 0, the pick ray of pickpoints are used 
                            as PickNormalsArray. Otherwise, the surface
              normals are used as PickNormalsArray.

TREAT_HOLES                 If 1, CrvOnSurf treats the hole's case, where the
                            curve must bypass a hole
TREAT_PEAKS                 If 1, SurfPlaneCrv treats the peak's case, where
                            the curve must circumvent a peak.

USE_PRJ_POINTS          Include projected points in the final curve
USE_INT_POINTS          Include intersection points in the final curve
USE_GETTRICLSTPOINT         If 1, uses R. Marques' algorithm for finding the
                            closest point in a triangle. Otherwise, use an
                            algorithm designed by David Eberly.


SHOW_PAUSED          Always Pauses after show something
SHOW_ALL          Enables all SHOW options bellow
SHOW_NONE          Disables all SHOW options bellow

SHOW_INSTANCE        CurveOnSurface instantiation. Also allows 
              clearing screen (prompt asks user). 
SHOW_CURVE_CREATION      Print Points Coords of curve on surface, 
              in creation order
SHOW_CURVE_POINTS      Print Points Coords of final curves.
SHOW_ERROR          Print error messages
SHOW_SEARCH          Print Triangle and Edge Indexes of Mesh for
              each curve on surface point
SHOW_TIMES          Print time taken to do CurveOnSurface operations

SHOW_PICK_POINTS      Print PickPoints Coords on screen
SHOW_PICK_POINT_NORMALS    Print PickPoints Normal Coords on screen
SHOW_LEFTPLANE        Print coords of 3 points in the 
              left (delimiter) plane
SHOW_RIGHTPLANE        Print coords of 3 points in the 
              right (delimiter) plane
SHOW_CUTPLANE        Print coords of 3 points in the 
              cut (intersection) plane
SHOW_CHECKLIMITS      Print discarded intersection points info
SHOW_CANDIDATES        Print triangles potentially at intersection


***************
OBS 1: If both USE options are set as 0, then a curve using intersection
points only will be created.

OBS 2: Custom SHOW options will be used only if SHOW_ALL and SHOW_NONE are disabled.
*/

//*************** Settings (You may overwrite this part only)
/* Test Type Options */
#define CILAMCE                 0 // Available for CrvOnSurf and PrjCrvOnSurf only

#define TREAT_HOLES             1 // Available for CrvOnSurf only
#define TREAT_PEAKS             1 // Available for SurfPlaneCrv only

#define USE_PRJ_POINTS          1 // Available for PrjCrvOnSurf, FootprintCrv and PrjWireCrv only
#define USE_INT_POINTS          1 // Available for PrjCrvOnSurf, FootprintCrv and PrjWireCrv only
#define USE_GETTRICLSTPOINT     1 // Available for PrjWireCrv only

#if _DEBUG

#include <stdio.h>
#include <time.h>

/* General Displaying Options */
/*
OBS: SHOW_ALL and SHOW_NONE are mutually exclusive. If both of them are set 
as 1, then will prevail SHOW_ALL.Else if, both of them are 0, will 
prevail the Custom Displaying Options.
*/
#define SHOW_ALL          0
#define SHOW_NONE          0
#define SHOW_PAUSED          0


/* Custom Displaying Options */ 
/*
OBS: Available only if SHOW_ALL and SHOW_NONE are 0
*/
#define SHOW_INSTANCE        0 // Available for all
#define SHOW_ERROR          0 // Available for all
#define SHOW_TIMES          0 // Available for all
#define SHOW_CURVE_CREATION      1 // Available for all
#define SHOW_SEARCH          0 // Available for all
#define SHOW_CURVE_POINTS      1 // Available for all
#define PRINT_FILE                  0//1 // Available for all

#define SHOW_PICK_POINTS      0//1 // Available for CrvOnSurf and PrjCrvOnSurf only
#define SHOW_PICK_POINT_NORMALS    0//1 // Available for CrvOnSurf and PrjCrvOnSurf only
#define SHOW_PICK_TRI        0//1 // Available for CrvOnSurf and PrjCrvOnSurf only
#define SHOW_LEFTPLANE        0//1 // Available for CrvOnSurf and PrjCrvOnSurf only
#define SHOW_RIGHTPLANE        0//1 // Available for CrvOnSurf and PrjCrvOnSurf only
#define SHOW_CUTPLANE        0//1 // Available for CrvOnSurf, SurfPlaneCrv and PrjCrvOnSurf only
#define SHOW_CHECKLIMITS      0 // Available for CrvOnSurf and PrjCrvOnSurf only

#define SHOW_CANDIDATES        1 // Available for SurfSurfCrv only


//****************

/**************** Internal Definitions (DO NOT OVERWRITE!!!!) */
#if SHOW_ALL
#undef SHOW_INSTANCE
#undef SHOW_PICK_POINTS      
#undef SHOW_PICK_POINT_NORMALS  
#undef SHOW_PICK_TRI
#undef SHOW_CURVE_CREATION    
#undef SHOW_LEFTPLANE        
#undef SHOW_RIGHTPLANE        
#undef SHOW_CUTPLANE
#undef SHOW_CHECKLIMITS
#undef SHOW_ERROR
#undef SHOW_SEARCH
#undef SHOW_TIMES


#define SHOW_INSTANCE        1
#define SHOW_PICK_POINTS      1
#define SHOW_PICK_POINT_NORMALS    1
#define SHOW_PICK_TRI        1
#define SHOW_CURVE_CREATION      1
#define SHOW_LEFTPLANE        1
#define SHOW_RIGHTPLANE        1
#define SHOW_CUTPLANE        1
#define SHOW_CHECKLIMITS      1
#define SHOW_ERROR          1
#define SHOW_SEARCH          1
#define SHOW_TIMES          1

#elif SHOW_NONE

#undef SHOW_INSTANCE
#undef SHOW_PICK_POINTS      
#undef SHOW_PICK_POINT_NORMALS    
#undef SHOW_PICK_TRI
#undef SHOW_CURVE_CREATION  
#undef SHOW_LEFTPLANE        
#undef SHOW_RIGHTPLANE        
#undef SHOW_CUTPLANE
#undef SHOW_CHECKLIMITS
#undef SHOW_ERROR
#undef SHOW_SEARCH
#undef SHOW_TIMES


#define SHOW_INSTANCE        0
#define SHOW_PICK_POINTS      0
#define SHOW_PICK_POINT_NORMALS    0
#define SHOW_PICK_TRI        0
#define SHOW_CURVE_CREATION      0
#define SHOW_LEFTPLANE        0
#define SHOW_RIGHTPLANE        0
#define SHOW_CUTPLANE        0
#define SHOW_CHECKLIMITS      0
#define SHOW_ERROR          0
#define SHOW_SEARCH          0
#define SHOW_TIMES          0

#endif

#endif

#if !USE_INT_POINTS && !USE_PRJ_POINTS
#undef USE_INT_POINTS
#define USE_INT_POINTS 1
#endif

//****************

/*************************************************************************/
#endif